package com.mes.biz.domain;

import com.mes.common.annotation.Excel;
import com.mes.common.core.domain.BaseEntity;
import com.mes.common.utils.log.annotation.FieldRemark;
import com.mes.common.utils.log.annotation.LogField;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import javax.validation.constraints.NotBlank;

/**
 * 审批权限设置对象 biz_approval_setting
 * @author hwg
 * @email hwg
 * @date 2023-05-01
 */
@Data
public class BizApprovalSetting extends BaseEntity<BizApprovalSetting>
{
    private static final long serialVersionUID = 1L;

    /** 单据类型 */
    @Excel(name = "单据类型", dictType = "document_type")
    @NotBlank(message = "单据类型不允许为空")
    @LogField
    @FieldRemark(name = "单据类型",field = "documentType")
    private String documentType;

    /** 审批步骤 */
    @Excel(name = "审批步骤", dictType = "sale_order_approval_step")
    @NotBlank(message = "审批步骤不允许为空")
    @LogField
    @FieldRemark(name = "审批步骤",field = "approveStep")
    private String approveStep;

    /** 审批人 */
    @Excel(name = "审批人")
    @NotBlank(message = "审批人不允许为空")
    @LogField
    @FieldRemark(name = "审批人",field = "approvePerson")
    private String approvePerson;

    private String approvePersonName;
    /** 租户id */
    private String tenantId;

    public void setDocumentType(String documentType)
    {
        this.documentType = documentType;
    }

    public String getDocumentType()
    {
        return documentType;
    }

    public void setApproveStep(String approveStep)
    {
        this.approveStep = approveStep;
    }

    public String getApproveStep()
    {
        return approveStep;
    }

    public void setApprovePerson(String approvePerson)
    {
        this.approvePerson = approvePerson;
    }

    public String getApprovePerson()
    {
        return approvePerson;
    }
    public void setApprovePersonName(String approvePersonName)
            {
            this.approvePersonName = approvePersonName;
            }

    public String getApprovePersonName()
            {
            return approvePersonName;
            }

    public void setTenantId(String tenantId)
    {
        this.tenantId = tenantId;
    }

    public String getTenantId()
    {
        return tenantId;
    }


    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
            .append("documentType", getDocumentType())
            .append("approveStep", getApproveStep())
            .append("approvePerson", getApprovePerson())
            .append("tenantId", getTenantId())
            .append("remark", getRemark())
            .append("id", getId())
            .append("createBy", getCreateBy())
            .append("createDept", getCreateDept())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .append("updateIp", getUpdateIp())
            .append("version", getVersion())
            .append("delFlag", getDelFlag())
            .toString();
    }
}
